<!-- home -->
<template>
  <div class="index-container">
    <div style="margin-top: 40px;">
      <van-row justify="space-around" type="flex">
        <van-col span="20">
          <van-field
            readonly
            clickable
            name="picker"
            :value="value"
            placeholder="请选择项目"
            @click="showProduct"
          />
        </van-col>
        <van-popup v-model="showPicker" position="bottom">
          <van-picker
            show-toolbar
            :columns="columns"
            @confirm="onConfirm"
            @cancel="showPicker = false"
          />
        </van-popup>
      </van-row>
    </div>
    <div style="margin-top: 40px;" v-show="showQuery">
      <van-row justify="space-around" type="flex">
        <van-col span="8">
          <span>归属机构</span>
        </van-col>
        <van-col span="8">
          <span>44031702-松岗营业部</span>
        </van-col>
      </van-row>
      <van-row justify="space-around" type="flex">
        <van-col span="8">
          <span>归属业务员</span>
        </van-col>
        <van-col span="8">
          <span>林志恒</span>
        </van-col>
      </van-row>
      <van-row justify="space-around" type="flex">
        <van-col span="8">
          <span>业务来源</span>
        </van-col>
        <van-col span="8">
          <span>直销</span>
        </van-col>
      </van-row>
      <van-row justify="space-around" type="flex">
        <van-col span="8">
          <span>归属机构</span>
        </van-col>
        <van-col span="8">
          <span>展业人员</span>
        </van-col>
      </van-row>
    </div>
    <div style="margin-top: 40px;">
      <van-row justify="space-around" type="flex">
        <van-col span="20">
          <van-button type="primary" v-show="showQuery" block>查询</van-button>
        </van-col>
      </van-row>
    </div>
  </div>
</template>

<script>
export default {
  data () {
    return {
      value: '',
      columns: ['杭州', '宁波', '温州', '嘉兴', '湖州'],
      showPicker: false,
      showQuery: false
    }
  },
  created () { },
  computed: {},
  methods: {
    onConfirm (value) {
      this.value = value
      this.showPicker = false
      this.showQuery = true
    },
    showProduct () {
      this.showPicker = true
    }
  }
}
</script>
<style lang="scss" scoped>
.index-container {
}
</style>
